#ifndef __CROSS_CAMERA
#define __CROSS_CAMERA

#define DEFAULT_UP_VECTOR D3DXVECTOR3( 0, 1, 0 )

class CCF_Camera : public CCF_EngineElement
{
private:
  D3DXMATRIX m_result;
  D3DXMATRIX m_projection;
  D3DXMATRIX m_invertView;

public:
  D3DXVECTOR3 Position;
  D3DXVECTOR3 Direction;
  D3DXVECTOR3 Up;

  CCF_Camera(void);
  ~CCF_Camera(void);

  void SetCamera( D3DXVECTOR3 pos, D3DXVECTOR3 dir, D3DXVECTOR3 up );

  void GoFront( double points );
  void GoBack( double points );
  void GoLeft( double points );
  void GoRight( double points );
  void GoUp( double points );
  void GoDown( double points );

  void TurnLeft( double angle );
  void TurnRight( double angle );
  void TiltFront( double angle );
  void TiltBack( double angle );
  void TiltLeft( double angle );
  void TiltRight( double angle );

  D3DXMATRIX* CalcViewMatrix();
  D3DXMATRIX* CalcProjectionMatrix();
  D3DXMATRIX* CalcInvertViewMatrix();
};

#endif